<%@ page contentType="text/html;charset=UTF-8" %>
<style>
</style>
  <header class="main-header" style="top:0;">
  <a href="${page_web}/user/index" class="logo">
		      <span class="logo-mini" style="margin-left: 8px;"><b>用户</b></span>
		      <span class="logo-lg text-center"><i class="fa fa-user"></i> 用户中心</span>
		    </a>
		    
 <script> 
  $(function(){
	if(${null==loginUser}){//此处警告不影响代码
		 window.location.href="/";
	}
  });
  </script>
    <!-- Header Navbar: style can be found in header.less -->
    <nav class="navbar navbar-static-top" style="height: 50px;">
    <!-- 
    <a href="#" class="sidebar-toggle" data-toggle="offcanvas" role="button">
        <span class="sr-only">Toggle navigation</span>
      </a>
      --> 
      <div class="navbar-custom-menu">
        <ul class="nav navbar-nav">
          <li><a href="${page_web}/user/index"><i class="fa fa-home"></i> HOME</a></li>
          <li><a href="${ctx}/sendPage/sale/web/trans/my-trans"><i class="fa fa-ra"></i> 交易大盘</a></li>
        <!--   <li class="dropdown tasks-menu">
            <a href="#" class="dropdown-toggle" data-toggle="dropdown"  style="height:50px;">
              <i class="fa fa-comments-o"></i>
              <span class="label label-danger countNotice"></span>
            </a>
            <ul class="dropdown-menu">
              <li class="header">您有<span class="countNotice"></span>条未读消息</li>
              <li>
                <ul class="menu">
                  <li>
                  </li>
                </ul>
              </li>
              <li class="footer">
               <a href="${page_web}/user/message">查看所有</a>
              </li>
            </ul>
          </li>
          --> 
          <!-- User Account: style can be found in dropdown.less -->
          <li class="dropdown user user-menu">
            <a href="#" class="dropdown-toggle" data-toggle="dropdown">
				<i class="fa fa-user"></i>
              	<span class="hidden-xs">${loginUser.userCname}</span>
            </a>
            <ul class="dropdown-menu">
              <!-- User image -->
              <li class="user-header">
<%--                <img src="${version}/dist/img/user2-160x160.jpg" class="img-circle" alt="User Image">--%>
	 			<c:if test="${empty loginUser.user.userRemark}">
			        <img src="${ctx}/images/user/person2.png" class="img-circle" onclick="window.location.href='${ctx}/';"/>
			  	</c:if>
			  	<c:if test="${!empty loginUser.user.userRemark}">
			       <img src="${loginUser.user.userRemark}" class="img-circle"/>
			  	</c:if>
                <p>
                  ${loginUser.userCname} - ${loginUser.userType }
                  <small>${loginUser.email }</small>
                </p>
              </li>
              <!-- Menu Body -->
              <li class="user-body">
                <div class="row">
                  <div class="col-xs-4 text-center">
                    <a href="${page_web}/user/index">会员中心</a>
                  </div>
                  <!-- 
                  <div class="col-xs-4 text-center">
                    <a href="${page_web}/member/member-info">会员资料</a>
                  </div>
                  <div class="col-xs-4 text-center">
                    <a href="${page_web}/user/myCollection">我的收藏</a>
                  </div>
                   -->
                </div>
                <!-- /.row -->
              </li>
              <!-- Menu Footer-->
              <li class="user-footer">
               <!--  <div class="pull-left">
                  <a href="${ctx}/" class="btn btn-default btn-flat">网站门户</a>
                </div>
                 -->
                <div class="pull-right">
                  <a href="${ctx}/logout?go=/index-sale.jsp" class="btn btn-default btn-flat">退出</a>
                </div>
              </li>
            </ul>
          </li>
        </ul>
      </div>
    </nav>
  </header>
<script>
function noticeNum(){
	$.ajax({url: '${ctx}/doFM.action?doCode=Mcount',type: 'POST',data:{noticeStatus:'1',sortCode:'notice',sendCode:'${loginUser.userEname}'},
			cache: false,success: function(data){
				$(".countNotice").html(data);
			}  
	});
}
$(function(){
	noticeNum();
	//setInterval("noticeNum()",3000);
});


</script>  
  
  
